#pragma once

namespace My {

class WindowTipCtrl : public CToolTipCtrl 
{
private:
	void FillInWndInfo(TOOLINFO& ti, CWnd* pWnd) const;
public:
	void GetWndTipText(CString& str, CWnd* pWnd) const;
	
	BOOL AddWindow(CWnd* pWnd, UINT nIDText, LPCRECT lpRectTool = NULL);
	BOOL AddWindow(CWnd* pWnd, LPCTSTR lpszText = LPSTR_TEXTCALLBACK, LPCRECT lpRectTool = NULL);
	void DelWindow(CWnd* pWnd);
	void SetWindowRect(CWnd* pWnd, LPCRECT lpRect);
	void UpdateWndTipText(LPCTSTR lpszText, CWnd* pWnd);
	void UpdateWndTipText(UINT nIDText, CWnd* pWnd);
};

} // My
